import axios from 'axios';

export interface Record {
  id?: number;
  createtime?: number;
  updatetime?: number;
}

export interface Params extends Partial<Record> {
  current: number;
  pageSize: number;
}

export interface Res {
  list: Record[];
  total: number;
}

export function getData(data: any) {
  return axios({
    url: '/pc/task/list',
    method: 'post',
    data,
  });
}
export function getDetail(data: any) {
  return axios({
    url: '/pc/task/detail',
    method: 'post',
    data,
  });
}
export function saveData(data: any) {
  return axios({
    url: '/pc/task/save',
    method: 'post',
    data,
  });
}
export function delData(ids: string | number) {
  return axios({
    url: '/pc/student/del',
    method: 'delete',
    data: { ids },
  });
}

export function auditsData(data: any) {
  return axios({
    url: '/pc/student/audits',
    method: 'post',
    data,
  });
}
